import QtQuick 2.15
import QtQuick.Layouts 1.15
import QtQuick.Controls 2.15
import QtCharts 2.3

Item {
    width: Constants.width
    height: Constants.height

    StackLayout {
        id: chartStackLayout
        width: 100
        anchors.top: tabBar.bottom
        anchors.right: parent.right
        anchors.left: parent.left
        anchors.bottom: parent.bottom
        currentIndex: tabBar.currentIndex

        Item {
            CechartsView{}
        }

        Item {
            CechartsView{}

        }

        Item {
            CechartsView{}
        }
    }

    TabBar {
        id: tabBar
        currentIndex: 0
        anchors.top: parent.top
        anchors.right: chartStackLayout.right
        anchors.left: chartStackLayout.left

        TabButton {
            text: qsTr("七天内每天")
        }

        TabButton {
            text: qsTr("当月每天")
        }

        TabButton {
            text: qsTr("当年每月")
        }
    }


}
